/*
 * Copyright (C) 2021 Baidu, Inc. All Rights Reserved.
 */
package com.chukun.rpc.registry.lb;

import java.util.List;

/**
 * <p>负载均衡接口<p/>
 *
 * @author chukun
 * @version 1.0
 * @since 1.0-SNAPSHOT
 */
public interface ServiceLoadBalancer<T> {

    /**
     * 负载均衡
     * @param services
     * @param hash
     * @return
     * @throws Exception
     */
    T select (List<T> services, int hash) throws Exception;
}
